<template>
    <div class="box">
        <template  v-for="(item,index) in resultData">
            <div class="item" :key="index" style="color:#666">{{item}}</div>
        </template>

    </div>
</template>>

<script>
import { getItemMonitorWarningLog } from '@/api/index.js';
import bus from 'common/bus.js';
export default {
    data() {
        return {
            selectedMonID:'',
            resultData:[]
            
        }
    },
    components:{
      
    },
    created() {
    this.selectedMonID = this.$store.getters["ItemMonitorALL/getItem"];
    this.initGetData();

    bus.$emit("timerNewTodo", {
      name: this.timerName,
      eventName: this.timerEventName,
      interval: this.timerInterval,
      intervalNow: 0,
    });
       
       
    },
    mounted() {
         bus.$on("ItemMonitorALL", (msg) => {
      this.selectedMonID = msg;
    

      this.initGetData();
    });
        
    },
    computed: {

    },
    methods: {
        initGetData(){
            getItemMonitorWarningLog({cid:this.selectedMonID.MONID}).then(_=>{
                this.resultData=_;
                
            })
           

           
        },
       
    },
    beforeDestroy() {
    
        
        
    },
   
}
</script>

<style scoped>
.box{
    background: black;
    color: #fff;
    padding:5px;
    
}

</style>